package com.tmt.im.service.controller.vo;

import io.swagger.v3.oas.annotations.media.Schema;
import io.swagger.v3.oas.annotations.tags.Tag;
import jakarta.validation.constraints.Min;
import jakarta.validation.constraints.NotNull;
import jakarta.validation.constraints.Null;
import lombok.Getter;
import lombok.Setter;

import java.io.Serial;
import java.io.Serializable;

/**
 * @Description TODO
 * @Author wuyi
 * @Date 2024/8/17 16:55
 * @Version 1.0
 **/
@Getter
@Setter
@Tag(name = "聊天历史查询请求对象")
public class ChatDataQueryRequest implements Serializable {

    @Serial
    private static final long serialVersionUID = -401694959776763303L;

    @Schema(name = "sessionId", description = "聊天会话ID")
    @NotNull(message = "聊天会话ID不允许为空")
    private Long sessionId;

    @Null
    @Schema(name = "startId", description = "查询访问的起始ID", nullable = true)
    private Long startId;

    @Min(1)
    @Schema(name = "count", description = "期望返回的记录条数, 必须大于0")
    private int count;

    @Null
    @Schema(name = "like", description = "聊天内容匹配串", nullable = true)
    private String like;

    @Null
    @Schema(name = "type", description = "限定的聊天记录的类型", nullable = true)
    private String type;

    @Schema(name = "rollback？", description = "是否是查询时间更早的记录")
    private boolean rollback;

}
